home *** CD-ROM | disk | FTP | other *** search
/ InfoMagic Internet Tools 1993 July / Internet Tools.iso / RockRidge / mail / pine / imap-3.0 / ANSI / c-client / os_bsi.h < prev    next >
Encoding:
C/C++ Source or Header  |  1993-06-07  |  2.9 KB  |  76 lines

  1. /*
  2.  * Program:    Operating-system dependent routines -- BSDI BSD/386 version
  3.  *
  4.  * Author:       Mike Santangelo (based on NeXT port by Mark Crispin)
  5.  *               UMCEES/CBL Computer and Network Systems Department
  6.  *               Solomons, Maryland
  7.  *               Internet: mike@cbl.umd.edu
  8.  *
  9.  * Date:         5 March 1993
  10.  * Last Edited:  7 June 1993
  11.  *
  12.  * Copyright 1993 by the University of Washington
  13.  *
  14.  *  Permission to use, copy, modify, and distribute this software and its
  15.  * documentation for any purpose and without fee is hereby granted, provided
  16.  * that the above copyright notice appears in all copies and that both the
  17.  * above copyright notice and this permission notice appear in supporting
  18.  * documentation, and that the name of the University of Washington not be
  19.  * used in advertising or publicity pertaining to distribution of the software
  20.  * without specific, written prior permission.  This software is made available
  21.  * "as is", and
  22.  * THE UNIVERSITY OF WASHINGTON DISCLAIMS ALL WARRANTIES, EXPRESS OR IMPLIED,
  23.  * WITH REGARD TO THIS SOFTWARE, INCLUDING WITHOUT LIMITATION ALL IMPLIED
  24.  * WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE, AND IN
  25.  * NO EVENT SHALL THE UNIVERSITY OF WASHINGTON BE LIABLE FOR ANY SPECIAL,
  26.  * INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM
  27.  * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, TORT
  28.  * (INCLUDING NEGLIGENCE) OR STRICT LIABILITY, ARISING OUT OF OR IN CONNECTION
  29.  * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
  30.  *
  31.  */
  32.  
  33. extern int h_errno;
  34.  
  35. #define MAILFILE "/var/mail/%s"
  36. #define ACTIVEFILE "/usr/lib/news/active"
  37. #define NEWSSPOOL "/usr/spool/news"
  38. #define NEWSRC strcat (strcpy (tmp,myhomedir ()),"/.newsrc")
  39.  
  40. #include <stdlib.h>
  41. #include <string.h>
  42. #include <sys/types.h>
  43. #include <sys/dir.h>
  44. #include <sys/uio.h>        /* needed for writev() prototypes */
  45.  
  46. /* Dummy definition overridden by TCP routines */
  47.  
  48. #ifndef TCPSTREAM
  49. #define TCPSTREAM void
  50. #endif
  51.  
  52.  
  53. /* Function prototypes */
  54.  
  55. void rfc822_date (char *date);
  56. void *fs_get (size_t size);
  57. void fs_resize (void **block,size_t size);
  58. void fs_give (void **block);
  59. void fatal (char *string);
  60. char *strcrlfcpy (char **dst,unsigned long *dstl,char *src,unsigned long srcl);
  61. unsigned long strcrlflen (STRING *s);
  62. long server_login (char *user,char *pass,char **home,int argc,char *argv[]);
  63. char *myusername ();
  64. char *myhomedir ();
  65. char *lockname (char *tmp,char *fname);
  66. TCPSTREAM *tcp_open (char *host,int port);
  67. TCPSTREAM *tcp_aopen (char *host,char *service);
  68. char *tcp_getline (TCPSTREAM *stream);
  69. long tcp_getbuffer (TCPSTREAM *stream,unsigned long size,char *buffer);
  70. long tcp_getdata (TCPSTREAM *stream);
  71. long tcp_soutr (TCPSTREAM *stream,char *string);
  72. long tcp_sout (TCPSTREAM *stream,char *string,unsigned long size);
  73. void tcp_close (TCPSTREAM *stream);
  74. char *tcp_host (TCPSTREAM *stream);
  75. char *tcp_localhost (TCPSTREAM *stream);
  76.